from redis import StrictRedis


class Config:
    SECRET_KEY = '1245667'
    DEBUG = None
    SESSION_TYPE = 'redis'
    SESSION_REDIS = StrictRedis(host='localhost', port=6379)
    SESSION_USE_SIGNER = True
    PERMANENT_SESSION_LIFETIME = 86400

    SQLALCHEMY_DATABASE_URI = 'mysql://root:mysql@localhost/info14'
    SQLALCHEMY_TRACK_MODIFICATIONS = True


class DevelopmentConfig(Config):
    DEBUG = True


class ProductionConfig(Config):
    DEBUG = False

dict_config = {
    'development':DevelopmentConfig,
    'production':ProductionConfig
}